from selenium.webdriver.common.by import By

from base import Base
class Page (Base):
#点击搜索栏
    def find_sousuo(self):
        loc=(By.ANDROID_UIAUTOMATOR,'new UiSelector().text("搜索菜谱")')
        ele=self.dingwei(loc)
        return ele
    def find_shuru(self):
        loc=(By.ID,'com.xiachufang:id/search_edit_text')
        ele=self.dingwei(loc)
        return ele
    def find_anniusousuo(self):
        loc=(By.XPATH,'//android.widget.TextView[@text="搜索"]')
        ele=self.dingwei(loc)
        return ele
    def find_dianji(self):
        loc=(By.XPATH,'(//android.widget.ImageView[@resource-id="com.xiachufang:id/common_photo_image_view"])[1]')
        ele=self.dingwei(loc)
        return ele





